Skip to content

Backend structure#520

Merged
abhishek-8081 merged 2 commits into
fireform-core:developmentfrom
chetanr25:backend_structure
Jun 2, 2026
Merged

Backend structure#520
abhishek-8081 merged 2 commits into
fireform-core:developmentfrom
chetanr25:backend_structure

Conversation

@chetanr25

Copy link
Copy Markdown
Collaborator

Restructure backend into a single layered app/ package

As Discussed in #501.

What

Consolidates the two top-level Python folders (api/ FastAPI service + src/ LLM/PDF engine) into one importable app/ package with clear layers.

app/
  main.py          # create_app() factory + lifespan
  api/
    router.py      # aggregates all routers
    routes/        # forms.py, templates.py
    schemas/
    deps.py
  core/            # config, logging, lifespan, error handlers
  services/        # llm, file_manipulator, filler, controller (was src/)
  models/          # ORM models
  db/              # database, init_db, repositories

Changes

  • All internal imports rewritten from api.* / src.* to app.*.
  • Entry-point references updated to app.main:app (Dockerfile, docker-compose, Makefile, release workflow).
  • Scattered os.getenv calls and runtime paths are centralized in app/core/config.py, and the old src/main.py demo now lives at examples/pipeline_demo.py.

Closes #513 .
Part of #512.

@chetanr25 chetanr25 changed the base branch from develop to development May 30, 2026 18:33
@chetanr25 chetanr25 force-pushed the backend_structure branch from aa198a5 to f4ee6fe Compare May 30, 2026 19:13
@abhishek-8081

Copy link
Copy Markdown
Collaborator

Read through it. Layering is clean and the app.main:app entry-point updates across Dockerfile, compose, Makefile, and release workflow are all consistent. Centralizing config in app/core/config.py is the right call.

@abhishek-8081

Copy link
Copy Markdown
Collaborator

LGTM.

@abhishek-8081 abhishek-8081 merged commit f6f7180 into fireform-core:development Jun 2, 2026
@chetanr25 chetanr25 deleted the backend_structure branch June 12, 2026 15:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants